package com.ky.tms.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.ky.tms.entity.TmsCost;
import com.ky.tms.entity.TmsOrder;
import com.ky.tms.vo.CostExportVo;
import org.apache.ibatis.annotations.Param;

import java.math.BigDecimal;
import java.time.LocalDateTime;
import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author chengkaimao
 * @since 2020-03-24
 */
public interface TmsCostMapper extends BaseMapper<TmsCost> {

    List<TmsCost> dispatchPage (IPage<TmsCost> pagination, @Param("cost") TmsCost tmsCost);

    List<TmsCost> costReportPage (IPage<TmsCost> pagination, @Param("cost") TmsCost tmsCost);

    List<TmsCost> auditPage (IPage<TmsCost> pagination, @Param("cost") TmsCost tmsCost);

    List<TmsOrder> costOrders (@Param("lns") String[] lns);

    List<CostExportVo> costExport (@Param("cost") TmsCost tmsCost);

    BigDecimal sumFee (@Param("cost") TmsCost tmsCost);

    int delByLoadNo(@Param("updateUser")String updateUser, @Param("updateTime") LocalDateTime updateTime, @Param("ids")List<Long> ids);

    int checkFinish(@Param("ids")List<Long> ids, @Param("status") String status);

}
